package com.jffccloud.provider.api.service;

import com.jffccloud.common.web.wrapper.Wrapper;
import com.jffccloud.provider.api.model.Demo;
import com.jffccloud.provider.api.model.OrderDto;
import com.jffccloud.provider.api.service.hystrix.OrderFeignHystrix;
import com.jffccloud.provider.api.feign.OAuth2FeignAutoConfiguration;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient(value = "jffccloud-provider-order", configuration = OAuth2FeignAutoConfiguration.class,fallback = OrderFeignHystrix.class)
public interface OrderFeignApi {
    @RequestMapping(value = "/api/order/queryByOrderNo/{orderNo}")
    Wrapper<OrderDto> queryByOrderNo(@PathVariable("orderNo") String orderNo);
    @RequestMapping(value = "/api/insertDemo")
    Wrapper insertDemo(@RequestBody Demo demo);
}
